import type { PageParam, PageResult } from '@vben/request';
import type { Dayjs } from 'dayjs';
import { requestClient } from '#/api/shop-request';
/** 开卡 */
export function openHandCard(cardId: number) {
  return requestClient.post('/spa/hand-card-action/open', { cardId });
}

/** 撤销 */
export function recallHandCard(cardId: number) {
  return requestClient.post('/spa/hand-card-action/recall', { cardId });
}

/** 通用动作 */
export function actionHandCard(params: { cardId: number; actionEnum: string }) {
  return requestClient.post('/spa/hand-card-action/action', params);
}

/** 修改状态 */
export function changeStatusHandCard(params: { cardId: number; newStatus: string }) {
  return requestClient.post('/spa/hand-card-action/change-status', params);
}

/** 合并 */
export function mergeHandCard(params: { sourceCardId: number; targetCardId: number }) {
  return requestClient.post('/spa/hand-card-action/merge', params);
}
